﻿<%@ Page Language="C#" AutoEventWireup="true"  CodeBehind="Default.aspx.cs" Inherits="webnew.Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>      
    <title><%=webnew.Common.CommonHelper.GetSystemName()%></title> 
    <link href="App_Themes/Style/Default.css" rel="stylesheet" type="text/css" /> 
    <base target="_self" />
</head>
<body>
    <div id="loading">
             <div class="loading-indicator">           
                 <img src="/App_Themes/Images/Default/loading.gif"  alt="" width="32" height="32" style="margin-right:8px;" align="absmiddle"/>             
                 <span id="loading-msg">loading...</span>
             </div>
    </div>
    <!-- ExtJS CSS -->
    <script type="text/javascript"> document.getElementById('loading-msg').innerHTML = '加载 主题组件...';</script>
    <link href="Ext/resources/css/ext-all.css" rel="stylesheet" type="text/css" />  
    <link href="Ext/resources/css/" rel="stylesheet" type="text/css" />
     <!-- ExtJS All JS -->
    <script type="text/javascript"> document.getElementById('loading-msg').innerHTML = '加载 UI组件...';</script>
    <script type="text/javascript" src="ext/adapter/ext/ext-base.js"></script>   
    <script type="text/javascript" src="ext/ext-all.js"></script>
    <script src="Ext/ext-lang-zh_CN.js" type="text/javascript"></script>
    <!-- ExtJS config JS -->
    <script type="text/javascript"> document.getElementById('loading-msg').innerHTML = '加载 配置文件...';</script>
    <script src="Js/theme.js" type="text/javascript"></script>  
    <script src="Js/TabCloseMenu.js" type="text/javascript"></script>    
    <script src="Js/app.js" type="text/javascript"></script>
    <script src="Js/MyWindow.js" type="text/javascript"></script>
    <script type="text/javascript">        
       Ext.onReady(function() {
            SetTheme();   
            Ext.BLANK_IMAGE_URL = 'Ext/resources/images/default/tree/s.gif';   
            Ext.QuickTips.init();                                             
            //var companyname='<%=webnew.Common.CommonHelper.GetCommpanyName()%>' + '©CopyRight 2011 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;';
            var companyname='<%=webnew.Common.CommonHelper.GetCommpanyName()%>'+' ©CopyRight 2011  V<%=Ver %>'+'.111219';//版本号
            var todaystring ='今天是:<%=years %>年<%=months %>月<%=days%>日 星期<%=weekdays%> ';
            var ipstring='当前登录IP: '+'<%=getuserip()%>';
            //生成树菜单
            <%=GetTreeMenu()%>  
            //工作提醒面板 
            var tixingpanel = new Ext.Panel({
                    title: "<img src='/App_Themes/Images/Default/menu.gif' alt=''  style='vertical-align:middle'/>&nbsp;工作提醒",
                    html:"<div class='tixing'><a href='#'>待审核(3)</a></div><div class='tixing'><a href='#'>新邮件(5)</a>"
                    });                                                                            
            //西边面板，功能菜单   
            var west_item = new Ext.Panel({
                title: "<img src='/App_Themes/Images/Default/menu.gif' alt=''  style='vertical-align:middle'/>&nbsp;功能菜单",
                region: 'west',
                contentEl: 'west-div',
                split: true,
                border: true,
                collapsible: true,
                width: 200,
                minSize: 200,
                maxSize: 300,
                layout: "accordion",
                layoutConfig: {
                    animate: true
                },
                items: [<%=bingTreeToPanel()%>]
                // items: [tixingpanel,<%=bingTreeToPanel()%>]
            });
            
            //底部工具栏    
            var tb = new Ext.Toolbar({
                        renderTo: 'TwoToolbar',
                        border: false,
                        items: [                
                        { text: '修改密码',iconCls: "btn-xiugaimima", 
                          handler: function show(){addUrl("xiugaimima","Systems/S_ChangePWD.aspx",this.text)}  },"-" ,
                        { text: '注销' ,iconCls: "btn-zhuxiao", 
                          handler: function show(){window.location.href="quit.aspx?type=1";} }, "-" , 
                        { text: '退出',iconCls: "btn-tuichu", 
                          handler: function out(){if (window.confirm('您确定退出吗?'))window.location.href="quit.aspx";} }, "-" ,"->",
                        { xtype: "tbfill" }, { xtype: "tbtext", text: companyname , id: "toolbarCompanyName" }, 
                        "-" ,  new Ext.Toolbar.TextItem(ipstring), "-" ,  new Ext.Toolbar.TextItem(todaystring),"-" , 
                        { text: "收展", iconCls: "btn-expand", handler: function() { var a = Ext.getCmp("nortPanel"); if (a.collapsed) { a.expand(true); } else { a.collapse(true); } } },                 
                         "-" ,{ xtype: "combo", mode: "local", editable: false, value: "切换皮肤", width: 90, triggerAction: "all",
                             store: [["ext-all", "默认风格"], ["xtheme-gray", "银白风格"], 
                                     ["xtheme-olive", "绿色风格"], ["xtheme-darkgray", "灰色风格"], 
                                     ["xtheme-purple", "紫色风格"], ["xtheme-slate", "深蓝风格"], 
                                     ["xtheme-slickness", "黑色风格"]], 
                            listeners: { scope: this, "select": 
                            function(d, b, c) { if (d.value != "") { changecss(d.value); } } }}
                    ]});
             //弹出右下角窗体并显示指定地址页面，参数：窗体ID，链接地址，窗体标题。
             this.addWin = function(winid, url, titles) {
                var Reminidwin = Ext.get(winid)
                if (Reminidwin) {
                    Reminidwin.open();
                    return;
                }
                Reminidwin = new MyWindow.TipsWindow({
                        id: winid,
                        title: titles,
                        modal: false,
                        width: 450,
                        height: 300,
                        maximizable: true,
                        resizable: true,
                        closeAction:'close',               
                        autoHide: 5,
                        html: '<iframe src="" name="ifrWin" id="ifrWin"  width="100%" height="100%"  frameborder="0" scrolling="auto" style="border:0px none; background-color:#BBBBBB; "  ></iframe>'
                    }).show();
                    ifrWin.location.href = url;        
             }       
               this.showWin=function (id)
               {      
                 var win = Ext.getCmp(id);
                 win.show();          
               }
             //addWin("ReminidWin","Homepage.aspx","作业通知");  
             //addWin("ReminidWin","Web/BasicData/B_WorkNoticeList.aspx","作业通知");               
             var appView=  new Ext.Viewport({
                    layout: "border",
                    items: [north_item, south_item, west_item, center_item]
                });    
             //east_item.collapse(true);            
             Ext.removeNode(Ext.getDom("loading"));
        });   
                      
    </script>   
    <div id="north-div" >  
         <div id="app-header">
         <div id="header-left">
				<%--<img id ="CompanyLogo" src="/App_Themes/Images/Default/shihuaLogo.png" alt="" height="50" style="max-width:230px;"/>--%>
	     </div>
	     <div id="header-main">
				<div id="topInfoPanel" style="float:left;padding-bottom: 4px">
					<div id="welcomeMsg">
					<span><img src="/App_Themes/Images/Default/icon_user.gif"  width="14" height="14" alt="" style="vertical-align:middle"/>欢迎您:<%=this.UserInfor.truename%></span>&nbsp;&nbsp;
                    <span><img src="/App_Themes/Images/Default/list_users.gif"  width="14" height="14" alt="" style="vertical-align:middle" />登录名:<%= this.UserInfor.Loginid %></span>&nbsp;&nbsp;                  
					<img src="/App_Themes/Images/Default/clock.gif" width="14" height="14" alt="" style="vertical-align:middle" />上次登录时间:<%= this.UserInfor.lastLogTime%>&nbsp;&nbsp;								
					 
					</div>
				</div>
				<div class="clear"></div>
				<ul id="header-topnav">	
				    <%--<li class="activeli"><a href="#" onclick="addUrl('shoujianxiang','Web/Office/Off_SendMail.aspx','收件箱','/App_Themes/Images/Default/receivemail.gif');" class="menu-shoujian">收件箱</a></li>
					<li class="commonli"><a href="#" onclick="addUrl('fajianxiang','Web/Office/Off_SendMail.aspx','发件箱','/App_Themes/Images/Default/sendmail.gif');" class="menu-fajian">发件箱</a></li>
					<li class="commonli"><a href="#" onclick="addUrl('renwu','Web/Office/','任务','/App_Themes/Images/Default/task.png');" class="menu-task">任务</a></li>
					<li class="commonli"><a href="#" onclick="addUrl('jihua','Web/Office/','计划','/App_Themes/Images/Default/workplan.png');" class="menu-workPlan">计划</a></li>
					<li class="commonli"><a href="#" onclick="addUrl('wendang','Web/Office/','文档','/App_Themes/Images/Default/documentation.gif');" class="menu-document">文档</a></li>	--%>
				</ul>
			</div>
			<div id="header-right">
				<div id="setting">
				   
				</div>
				<div id="searchFormDisplay" style="width:160px;float:right;padding-top:8px;">
				    	<%--<span><img src="/App_Themes/Images/Default/icon_key.gif"  width="16" height="16" alt="" style="vertical-align:middle"/><a href="#">修改密码</a></span>
				   <span><img src="/App_Themes/Images/Default/delete.gif"  width="16" height="16" alt="" style="vertical-align:middle"/><a href="#">注销</a> </span>    --%>            		 
				</div>
		   </div>        
       </div>             
    </div>  
    <div id="south-div"><div id ="TwoToolbar"></div> </div>
    <div id="west-div"></div>  
    <div id='center-center'></div>  
    <div id='center-south'></div>     
</body>
</html>
